<!DOCTYPE html>
<html lang="en">
<head>
    <meta charset="UTF-8">
    <meta name="viewport" content="width=device-width, initial-scale=1.0">
    <meta http-equiv="X-UA-Compatible" content="ie=edge">
    <title>Document</title>
</head>
<style type="text/css">
span.s2{
color: red
}
.s2span{
color: red
}
</style>
<body>
    <span id="s1" class="s2">这是一个span</span>
    <span>这是第二个span</span>
</body>
</html>